# Add the standalone toolchain to the search path.
export NDK=$ANDROID_HOME/ndk/21.0.6113669
export TOOLCHAIN=$NDK/toolchains/llvm/prebuilt/darwin-x86_64

# Tell configure what tools to use.
export TARGET=armv7a-linux-androideabi
export API=21

#Configure
export AR=$TOOLCHAIN/bin/llvm-ar
export CC=$TOOLCHAIN/bin/$TARGET$API-clang
export AS=$CC
export CXX=$TOOLCHAIN/bin/$TARGET$API-clang++
export LD=$TOOLCHAIN/bin/ld
export RANLIB=$TOOLCHAIN/bin/llvm-ranlib
export STRIP=$TOOLCHAIN/bin/llvm-strip
export READELF=$TOOLCHAIN/bin/llvm-readelf

# Tell configure what flags Android requires.
export CFLAGS="-fPIC"
export CPPFLAGS=$CFLAGS
#export LDFLAGS="-pie"
